#include "StdAfx.h"
#include "Matrix.h"

CMatrix::CMatrix(CPoint p)
{
	this->num1.x = p.x;
	this->num1.y = p.y;
}

CMatrix::CMatrix(void)
{
}


CMatrix::~CMatrix(void)
{
}

CPoint CMatrix::add(CPoint p)
{
	this->num1.x = this->num1.x + p.x;
	this->num1.y = this->num1.y + p.y;
	return this->num1;
}
CPoint CMatrix::minus(CPoint p)
{
	this->num1.x = this->num1.x - p.x;
	this->num1.y = this->num1.y - p.y;
	return this->num1;
}
CPoint CMatrix::mul(CPoint p)
{
	this->num1.x = this->num1.x * p.x;
	this->num1.y = this->num1.y * p.y;
	return this->num1;
}
CPoint CMatrix::mul(double scale)
{
	this->num1.x = this->num1.x * scale;
	this->num1.y = this->num1.y * scale;
	return this->num1;
}